package com.zzj.controller;


import com.zzj.bean.TabPower;
import com.zzj.service.TabPowerService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
 * <p>
 * InnoDB free: 8192 kB 前端控制器
 * </p>
 *
 * @author 花
 * @since 2022-03-04
 */
@RestController
@RequestMapping("/power")
@Api
@CrossOrigin
public class TabPowerController {

    @Autowired
    private TabPowerService powerService;

    @GetMapping("getPower/{uid}")
    @ApiOperation("获取权限")
    public List<TabPower> getPower(@PathVariable("uid") String uid){
        return powerService.findPowerByUserId(uid);
    }
}

